home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / C and C++ / Entertainment / MacMud / Unix / errno.h < prev    next >
Encoding:
C/C++ Source or Header  |  1987-08-12  |  3.7 KB  |  99 lines  |  [TEXT/MPS ]

  1.  
  2. #ifndef __ERRNO__
  3. #define __ERRNO__
  4. /*
  5.  * Error codes.  Replaces MPW include file :Cincludes:ErrNo.h
  6.  */
  7.  
  8. extern int errno;
  9.  
  10. #define    EPERM        1        /* Not owner */
  11. #define    ENOENT        2        /* No such file or directory */
  12. #define    ESRCH        3        /* No such process */
  13. #define    EINTR        4        /* Interrupted system call */
  14. #define    EIO            5        /* I/O error */
  15. #define    ENXIO        6        /* No such device or address */
  16. #define    E2BIG        7        /* Arg list too long */
  17. #define    ENOEXEC        8        /* Exec format error */
  18. #define    EBADF        9        /* Bad file number */
  19. #define    ECHILD        10        /* No children */
  20. #define    EAGAIN        11        /* No more processes */
  21. #define    ENOMEM        12        /* Not enough core */
  22. #define    EACCES        13        /* Permission denied */
  23. #define    EFAULT        14        /* Bad address */
  24. #define    ENOTBLK        15        /* Block device required */
  25. #define    EBUSY        16        /* Mount device busy */
  26. #define    EEXIST        17        /* File exists */
  27. #define    EXDEV        18        /* Cross-device link */
  28. #define    ENODEV        19        /* No such device */
  29. #define    ENOTDIR        20        /* Not a directory*/
  30. #define    EISDIR        21        /* Is a directory */
  31. #define    EINVAL        22        /* Invalid argument */
  32. #define    ENFILE        23        /* File table overflow */
  33. #define    EMFILE        24        /* Too many open files */
  34. #define    ENOTTY        25        /* Not a typewriter */
  35. #define    ETXTBSY        26        /* Text file busy */
  36. #define    EFBIG        27        /* File too large */
  37. #define    ENOSPC        28        /* No space left on device */
  38. #define    ESPIPE        29        /* Illegal seek */
  39. #define    EROFS        30        /* Read-only file system */
  40. #define    EMLINK        31        /* Too many links */
  41. #define    EPIPE        32        /* Broken pipe */
  42.  
  43. /* math software */
  44. #define    EDOM        33        /* Argument too large */
  45. #define    ERANGE        34        /* Result too large */
  46.  
  47. /* non-blocking and interrupt i/o */
  48. #define    EWOULDBLOCK    35        /* Operation would block */
  49. #define    EINPROGRESS    36        /* Operation now in progress */
  50. #define    EALREADY    37        /* Operation already in progress */
  51. /* ipc/network software */
  52.  
  53.     /* argument errors */
  54. #define    ENOTSOCK    38        /* Socket operation on non-socket */
  55. #define    EDESTADDRREQ    39        /* Destination address required */
  56. #define    EMSGSIZE    40        /* Message too long */
  57. #define    EPROTOTYPE    41        /* Protocol wrong type for socket */
  58. #define    ENOPROTOOPT    42        /* Protocol not available */
  59. #define    EPROTONOSUPPORT    43        /* Protocol not supported */
  60. #define    ESOCKTNOSUPPORT    44        /* Socket type not supported */
  61. #define    EOPNOTSUPP    45        /* Operation not supported on socket */
  62. #define    EPFNOSUPPORT    46        /* Protocol family not supported */
  63. #define    EAFNOSUPPORT    47        /* Address family not supported by protocol family */
  64. #define    EADDRINUSE    48        /* Address already in use */
  65. #define    EADDRNOTAVAIL    49        /* Can't assign requested address */
  66.  
  67.     /* operational errors */
  68. #define    ENETDOWN    50        /* Network is down */
  69. #define    ENETUNREACH    51        /* Network is unreachable */
  70. #define    ENETRESET    52        /* Network dropped connection on reset */
  71. #define    ECONNABORTED    53        /* Software caused connection abort */
  72. #define    ECONNRESET    54        /* Connection reset by peer */
  73. #define    ENOBUFS        55        /* No buffer space available */
  74. #define    EISCONN        56        /* Socket is already connected */
  75. #define    ENOTCONN    57        /* Socket is not connected */
  76. #define    ESHUTDOWN    58        /* Can't send after socket shutdown */
  77. #define    ETOOMANYREFS    59        /* Too many references: can't splice */
  78. #define    ETIMEDOUT    60        /* Connection timed out */
  79. #define    ECONNREFUSED    61        /* Connection refused */
  80.  
  81.     /* */
  82. #define    ELOOP        62        /* Too many levels of symbolic links */
  83. #define    ENAMETOOLONG    63        /* File name too long */
  84.  
  85. /* should be rearranged */
  86. #define    EHOSTDOWN    64        /* Host is down */
  87. #define    EHOSTUNREACH    65        /* No route to host */
  88. #define    ENOTEMPTY    66        /* Directory not empty */
  89.  
  90. /* quotas & mush */
  91. #define    EPROCLIM    67        /* Too many processes */
  92. #define    EUSERS        68        /* Too many users */
  93. #define    EDQUOT        69        /* Disc quota exceeded */
  94.  
  95. /* Network File System */
  96. #define    ESTALE        70        /* Stale NFS file handle */
  97. #define    EREMOTE        71        /* Too many levels of remote in path */
  98.  
  99. #endif